package com.study.reflection;

import lombok.Data;

/**
 * @author: jzhou
 * @date: 2025/6/8-12:01
 * @version: 1.0
 * @description: juc-study
 */

@Data
public class User {

    private int age;

    private String name;

    private String job;

    //无参构造方法
    public User() {
    }

    private User(String name) {
        this.name = name;
    }

    //有参构造方法
    public User(int age, String name, String job) {
        this.age = age;
        this.name = name;
        this.job = job;
    }

    @Override
    public String toString() {
        return "User{" +
                "age=" + age +
                ", name='" + name + '\'' +
                ", job='" + job + '\'' +
                '}';
    }
}
